package com.sound.ampache;

/* Copyright (c) 2010 Brian Kirkman <kirkman.brian@gmail.com>
* 
* +------------------------------------------------------------------------+
* | This program is free software; you can redistribute it and/or          |
* | modify it under the terms of the GNU General Public License            |
* | as published by the Free Software Foundation; either version 3         |
* | of the License, or (at your option) any later version.                 |
* |                                                                        |
* | This program is distributed in the hope that it will be useful,        |
* | but WITHOUT ANY WARRANTY; without even the implied warranty of         |
* | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the          |
* | GNU General Public License for more details.                           |
* |                                                                        |
* | You should have received a copy of the GNU General Public License      |
* | along with this program; if not, write to the Free Software            |
* | Foundation, Inc., 59 Temple Place - Suite 330,                         |
* | Boston, MA  02111-1307, USA.                                           |
* +------------------------------------------------------------------------+
*
* Special thanks to the following: 
* Kevin Purdy, author of Amdroid, for much of the code used in this project
* 
* Jorge Ramon, author of MiamiCoder blog, for many great BlackBerry examples
* published on his blog.
* 
* 
*/

import net.rim.device.api.ui.*;

class ampacheberry extends UiApplication {
	
	public static HomeScreen homeScreen;
	public static ampacheCommunicator comm;
	public static SongPlaylist playlistSong; 
	public static CurrentPlaylistScreen playlistScreen;  
	public static ampacheCommunicator.perform_auth_request authReq;
    
	
	public static void main(String[] args){ 
		ampacheberry myApp = new ampacheberry();
		myApp.enterEventDispatcher();
	}
    
	
    public ampacheberry() {
    	comm = new ampacheCommunicator();
        playlistSong = new SongPlaylist();
        playlistScreen = new CurrentPlaylistScreen();
        authReq = comm.new perform_auth_request();
        homeScreen = new HomeScreen();
        SplashScreen.showScreen(authReq);
    }
    
    public static void getStoreData() {
    	comm.getStoreData();
     }
 
    
    public static void redrawHomescreen() {
    	homeScreen.drawMenu();
    }
} 
